-
Notifications
You must be signed in to change notification settings - Fork 10
DOCSP-51350: Vector search queries #117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
✅ Deploy Preview for docs-kotlin-sync ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
🔄 Deploy Preview for docs-kotlin-sync processing
|
source/atlas-vector-search.txt
Outdated
:atlas:`Atlas Vector Search </atlas-vector-search/vector-search-overview/>` | ||
queries. The ``Aggregates`` builders class provides the | ||
the ``vectorSearch()`` helper method, which you can use to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the ``vectorSearch()`` helper method, which you can use to | |
``vectorSearch()`` helper method, which you can use to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops thank you
source/includes/vector-search.kt
Outdated
// Specifies the path of the field to search | ||
val fieldSearchPath: FieldSearchPath = fieldPath("plot_embedding") | ||
|
||
// Creates the vector search pipeline stage with numCandidates and limit |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
given limit
is used prior to numCandidates
, it might be better to switch the order of them
source/includes/vector-search.kt
Outdated
val results = collection.aggregate(pipeline) | ||
|
||
results.forEach { doc -> | ||
val score = doc.getDouble("vectorSearchScore") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we really need the above statement? I assume vectorSearchScore
is a meta field name, but not the field name, so I guess doc.getDouble("vectorSearchScore")
will return null invariably?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No not necessary, I meant to take that line out - fixed!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Pull Request Info
PR Reviewing Guidelines
JIRA - https://jira.mongodb.org/browse/DOCSP-51350
Staging Links
Self-Review Checklist